import 'package:bitcoin_mine/pages/chat_customer_page.dart';
import 'package:get/get.dart';
import '../pages/main_page.dart';
import '../pages/withdraw_page.dart';
import '../pages/subscription_page.dart';
import '../pages/splash_page.dart';
import '../pages/user_settings_page.dart';
import '../pages/web_view_page.dart';

class AppRoutes {
  static const String splash = '/splash';
  static const String main = '/main';
  static const String withdraw = '/withdraw';
  static const String subscription = '/subscription';
  static const String testSubscription = '/test-subscription';
  static const String privacyTest = '/privacy-test';
  static const String userSettings = '/user-settings';
  static const String chatCustomer = '/chat-customer';
  static const String webView = '/web-view';
  static List<GetPage> routes = [
    GetPage(name: splash, page: () => const SplashPage()),
    GetPage(name: main, page: () => const MainPage()),
    GetPage(name: withdraw, page: () => const WithdrawPage()),
    GetPage(name: subscription, page: () => const SubscriptionPage()),
    GetPage(name: userSettings, page: () => const UserSettingsPage()),
    GetPage(name: chatCustomer, page: () => const ChatCustomerPage()),
    GetPage(
      name: webView,
      page: () {
        final args = Get.arguments as Map<String, dynamic>?;
        return WebViewPage(url: args?['url'] ?? '', title: args?['title']);
      },
    ),
  ];
}
